package fr.umlv.m2.ig.model.event;

import java.util.EventObject;

import fr.umlv.m2.ig.model.StationsTableModel.DisplayWay;

@SuppressWarnings("serial")
public class SearchEvent extends EventObject {
  /**
   * The name of search.
   */
  private final String name;
  
  /**
   * The way to display stations.
   */
  private final DisplayWay displayStationsWay;
  
  /**
   * Create a new {@code SearchEvent}.
   * 
   * @param source the source of the event.
   * @param name the name of search.
   */
  public SearchEvent(final Object source, final String name, final DisplayWay displayWay) {
    super(source);
    this.name = name;
    this.displayStationsWay = displayWay;
  }
  
  /**
   * Gets the name of search.
   * 
   * @return the name.
   */
  public String getName() {
    return this.name;
  }
  
  /**
   * Gets the display stations way.
   * 
   * @return the way.
   */
  public DisplayWay getDisplayStationsWay() {
    return this.displayStationsWay;
  }
}
